package gui.listener;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JButton;

import gui.panel.MainPanel;
import gui.panel.ReportPanel;
import gui.panel.ReportPanel1;
import gui.panel.ReportPanel2;

public class ReportListener implements ActionListener{
		@Override
		public void actionPerformed(ActionEvent e) {
	        ReportPanel p = ReportPanel.instance;
	        MainPanel mp = MainPanel.instance;
	        JButton b = (JButton) e.getSource();
	        if (b == p.breport) {
	        	mp.workingPanel.show(ReportPanel1.instance);
	        }
	        	
	        if (b == p.bspend) {
	        	mp.workingPanel.show(ReportPanel2.instance);
	        }
	    }
}
